<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title><?=$title?></title>	
	<meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <meta  http-equiv="description" content="Free open source blog software based on codeigniter." />
    <meta http-equiv="keywords" content="Free,open,source,blog,website,codeigniter,web design,speedovation,hosting" />
    <meta http-equiv="author" content="Yash Bharadwaj" />
	<link rel="stylesheet" href="<?=base_url()?>themes/default/css/default.css" type="text/css" media="screen, projection" />
	<link rel="stylesheet" href="<?=base_url()?>themes/default/css/winterblues.css" type="text/css" media="screen, projection" />
</head>

<body>

<div id="header">
		<!--
        you can use this for blog name and sllogan etc...
        < ?php
		$site_name=$this->config->item('site_name');
		$site_slogan=$this->config->item('site_slogan');
		$sub_site_slogan=$this->config->item('sub_site_slogan');
		 ?>
			<h1>< ?=anchor('blog/',$site_name,'Home')?> - < ?=$site_slogan?></h1>
		  <p>< ?=$sub_site_slogan?></p>
         -->  
          
            <div  class="top"> </div>
            <div  class="middle">
            		<div class="leftmenu"></div>	
                    <div class="centermenu">
                      		<ul id="nav">
                            		<li><?=anchor('blog/','Home');?></li>
									<?=$pages?>
                             </ul>
                    </div>		
                    <div class="rightmenu"></div>
            
            </div>
  <div class="bottom">&nbsp;</div>
 </div><!--end of header -->

<div id="blogbody">


     
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td  valign="top">
                    <div id="postarea">
                    
                            <div  class="top"> &nbsp;</div>
                            <div  class="middle">&nbsp;
                         
								<div id="post">
								<div class="top">&nbsp;</div>
								<div class="middle"><?php   
		switch($where)
		{		
		case 'post':  ?>
         
         <!--single post -->
          <h2><?=$post['title_link']?></h2>
		  <p class="post-info">Posted by <?=$post['author_name']?> | Filed under <?=$post['categories']?> </p>
		  <p><?=$post['content']?></p>
		  <p><?=$post['read_comments']?></p>
		  <p><?=$post['comment_form']?></p>
          
          <!--loop for posts  -->
          <?php	
		  					break; 
			case 'loop':  
		   			for($i=0;$i<count($allposts)-1;$i++)	
					{ $comments=base_url().'blog/post/'.url_title($allposts[$i]['post_title']).'#comments';
		   ?>
			
            
           <h2><?=$allposts[$i]['title_link'];?></h2>
           <p class="post-info">Posted by <?=$allposts[$i]['author_name'];?> | Posted on <?=$allposts[$i]['date'];?> | Filed under <?=$allposts[$i]['categories'];?> | <a href="<?=$comments?>" class="comments">Comments : <?=$allposts[$i]['comment_no'];?></a> </p>
		   <p><?=$allposts[$i]['content'];?></p>
			
				
            
     	<?php	} //end of for loop
		   echo $allposts['last'];
		
							break;
			case 'page':    ?>

            <h2><?=$page['title_link']?></h2>
		    <p><?=$page['content']?></p>
		  
		  <?php break;
		  case 'single':     ?>

           <p><?=$content?></p>

		  <?php break; } ?>
          </div>
                                <div class="bottom">&nbsp;</div>
                                </div> <!--end of post -->
                                       
                           
                            </div><!--end of #postarea  .middle  each post ,page ect will come inside this-->
                            <div class="bottom">&nbsp;</div>
                            
                  </div><!-- end of postarea-->
  </td>
    <td valign="top">
    <br /><br />

                 <div id="sidebar">

                              <?php 
			 echo $search_form;
			 echo $categories;
			 echo $latest_posts;
			 echo $latestcomment;
		     echo $archives;
			 echo $users;
			 echo $tag_clouds;			 
			 echo $calendar;
			?>
                     
                        
                            
                </div><!--end of sidebar -->
      </td>
  </tr>
</table>


	
</div>     <!-- end of blogbody-->

<div id="footer">
			<div  class="top"> &nbsp;</div>
			<div  class="middle"><!--<ul>
                        <li><a href="#">Home</a></li>
                   s     <li><a href="#">About</a></li>
                        <li><a href="#">Support</a></li>
                        <li><a href="#">Documentation</a></li>
                        <li><a href="#">Contact</a></li>
                      </ul>Blog Lower Links -->&nbsp;</div>
			<div class="bottom" >Powered by: <a href="http://speedovation.org">Blogmer</a> </div>
				
</div>


</body>
</html>
